<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <title>验证表单</title>
</head>

<body>
    @if(count($errors)>0)
    <div class="alert alert-danger">
        <ul>
            @foreach($errors->all() as $error)
            <li>{{$error}}</li>
            @endforeach
        </ul>
    </div>
    @endif

    <form action="" method="post">
        <p>姓名：<input type="text" name="name"></p>
        <p>年龄：<input type="text" name="age"></p>
        <p>邮箱：<input type="email" name="email"></p>
        <p>验证码：<input type="text" name="captcha"><img src="{{captcha_src()}}" alt="">
            {{ csrf_field() }}
            <input type="submit" value="提交">
    </form>

</body>

</html>